﻿@page "/samples/issue320"

<h3>Issue320</h3>

<div class="accordion">
    <BSCollapseGroup>
        @for (int i = 0; i < 5; i++)
        {
            int number = i + 1;
            <BSCollapseItem @key="@i">
                <BSCard CardType="CardType.Card">
                    <BSCard CardType="CardType.Header">
                        <BSCollapseToggle IsLink="true">Collapsable Group Item #@number</BSCollapseToggle>
                    </BSCard>
                    <BSCollapse>
                        <BSCard CardType="CardType.Body">
                            <BSCard CardType="CardType.Text">Anim pariatur cliche reprehenderit, enim eiusmod high life accusamus terry richardson ad squid. Nihil anim keffiyeh helvetica, craft beer labore wes anderson cred nesciunt sapiente ea proident.</BSCard>
                        </BSCard>
                    </BSCollapse>
                </BSCard>
            </BSCollapseItem>
        }
    </BSCollapseGroup>
</div>

<BSPagination>
    <BSPaginationItem>
        <BSPaginationLink Href="#" PaginationLinkType="PaginationLinkType.PreviousText" />
    </BSPaginationItem>
    <BSPaginationItem>
        <BSPaginationLink Href="#" PaginationLinkType="PaginationLinkType.Custom">1</BSPaginationLink>
    </BSPaginationItem>
    <BSPaginationItem>
        <BSPaginationLink Href="#" PaginationLinkType="PaginationLinkType.Custom">2</BSPaginationLink>
    </BSPaginationItem>
    <BSPaginationItem>
        <BSPaginationLink Href="#" PaginationLinkType="PaginationLinkType.Custom">3</BSPaginationLink>
    </BSPaginationItem>
    <BSPaginationItem>
        <BSPaginationLink Href="#" PaginationLinkType="PaginationLinkType.NextText" @onclick="onclick" OnClickPreventDefault="true" />
    </BSPaginationItem>
</BSPagination>

@code {
    //bool IsOpen { get; set; }
    //void onclick(MouseEventArgs e)
    //{
    //    IsOpen = !IsOpen;
    //    StateHasChanged();
    //}

    void onclick(MouseEventArgs e)
    {
        Console.WriteLine("inside toggle button clicked");
    }
}
